﻿package pk;

class FirstThread extends Thread{
   
    public void run(){
        for(int i=0;i<10;i++){
         
            System.out.println(this.getName()+"===="+i);
        }
    }
}


public class Demo1{

    public static void main(String[] args) {
        
        FirstThread t1=new FirstThread();
 
        t1.start();
        
        FirstThread t2=new FirstThread();
       
        t2.start();
        
        for(int i=0;i<10;i++){
          
            System.out.println(Thread.currentThread().getName()+"===="+i);
        }
    }
}